<template>
    <el-container class="app-container">
        <el-header class="app-header">
            <toolbar ref="toolbar"/>
        </el-header>
        <el-main class="app-main">
            <router-view></router-view>
        </el-main>
    </el-container>
</template>

<script>
import tnx from '@/tnx.js';
import toolbar from './toolbar.vue';

export default {
    components: {toolbar},
    data() {
        return {};
    },
    mounted() {
        tnx.app.global.toolbar = this.$refs.toolbar;
        let path = window.location.hash.substring(1);
        this.$router.push(path);
    },
    methods: {},
};
</script>

<style lang="scss" scoped>
.app-container {
    border-top: 1px solid var(--el-bg-color-page);

    .app-header {
        height: auto;
        padding: 0;
        background-color: var(--el-bg-color-page);
        border-bottom: 1px solid var(--el-border-color);
    }
}
</style>
